/**
 * 主导航
 */

//第一部分---导航
	
	//各个选项名称对应的内容数量
	_EsdDynamicTransformationScript.num1 = $("#nav>li:eq(1) .navContent ul a").length-1;
	_EsdDynamicTransformationScript.num2 = $("#nav>li:eq(2) .navContent ul a").length-1;
	_EsdDynamicTransformationScript.num3 = $("#nav>li:eq(3) .navContent ul a").length-1;
	_EsdDynamicTransformationScript.num4 = $("#nav>li:eq(4) .navContent ul a").length-1;
	_EsdDynamicTransformationScript.num5 = $("#nav>li:eq(5) .navContent ul a").length-1;
	
	//各个选项名称
	_EsdDynamicTransformationScript.esd0TagNum1 = $("#nav>li:eq(1) a:eq(0)");
	_EsdDynamicTransformationScript.esd0TagNum2 = $("#nav>li:eq(2) a:eq(0)");
	_EsdDynamicTransformationScript.esd0TagNum3 = $("#nav>li:eq(3) a:eq(0)");
	_EsdDynamicTransformationScript.esd0TagNum4 = $("#nav>li:eq(4) a:eq(0)");
	_EsdDynamicTransformationScript.esd0TagNum5 = $("#nav>li:eq(5) a:eq(0)");
	
	//各个选项中的第一个内容
	_EsdDynamicTransformationScript.esd0TagNum1Content1 = $("#nav>li:eq(1) .navContent ul a:eq(0)");
	_EsdDynamicTransformationScript.esd0TagNum2Content1 = $("#nav>li:eq(2) .navContent ul a:eq(0)");
	_EsdDynamicTransformationScript.esd0TagNum3Content1 = $("#nav>li:eq(3) .navContent ul a:eq(0)");
	_EsdDynamicTransformationScript.esd0TagNum4Content1 = $("#nav>li:eq(4) .navContent ul a:eq(0)");
	_EsdDynamicTransformationScript.esd0TagNum5Content1 = $("#nav>li:eq(5) .navContent ul a:eq(0)");
	
	//各个选项中的最后一个内容
	_EsdDynamicTransformationScript.esd0TagNum1ContentN = $("#nav>li:eq(1) .navContent ul a:eq("+_EsdDynamicTransformationScript.num1+")");
	_EsdDynamicTransformationScript.esd0TagNum2ContentN = $("#nav>li:eq(2) .navContent ul a:eq("+_EsdDynamicTransformationScript.num2+")");
	_EsdDynamicTransformationScript.esd0TagNum3ContentN = $("#nav>li:eq(3) .navContent ul a:eq("+_EsdDynamicTransformationScript.num3+")");
	_EsdDynamicTransformationScript.esd0TagNum4ContentN = $("#nav>li:eq(4) .navContent ul a:eq("+_EsdDynamicTransformationScript.num4+")");
	_EsdDynamicTransformationScript.esd0TagNum5ContentN = $("#nav>li:eq(5) .navContent ul a:eq("+_EsdDynamicTransformationScript.num5+")");
	
	//各个选项名称对应区域（调整display--none/block）
	_EsdDynamicTransformationScript.esd0TagNum1Area = $("#nav>li:eq(1) .navContent");
	_EsdDynamicTransformationScript.esd0TagNum2Area = $("#nav>li:eq(2) .navContent");
	_EsdDynamicTransformationScript.esd0TagNum3Area = $("#nav>li:eq(3) .navContent");
	_EsdDynamicTransformationScript.esd0TagNum4Area = $("#nav>li:eq(4) .navContent");
	_EsdDynamicTransformationScript.esd0TagNum5Area = $("#nav>li:eq(5) .navContent");
	
	
	
	//第一块
	_EsdDynamicTransformationScript.esd0TagNum1.focus(function (e) {
		_EsdDynamicTransformationScript.esd0TagNum1Area.css({"display":"block"});
//		e = $(this).mouseover();
		$(this).bind("keydown.keydown00_1", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				_EsdDynamicTransformationScript.esd0TagNum1Area.attr("style","");
			}else if (e.keyCode == 9) {
				console.log("1");
				_EsdDynamicTransformationScript.esd0TagNum1Content1.focus();
				console.log(document.activeElement);
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd0TagNum1.blur(function () {
		$(this).unbind("keydown.keydown00_1");
	});

	_EsdDynamicTransformationScript.esd0TagNum1Content1.focus(function () {
		$(this).bind("keydown.keydown00_s1", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd0TagNum1.focus();
				return false;
			}else if (e.keyCode == 9) {
				
			}
		});
	});
	_EsdDynamicTransformationScript.esd0TagNum1Content1.blur(function () {
		$(this).unbind("keydown.keydown00_s1");
	});

	_EsdDynamicTransformationScript.esd0TagNum1ContentN.focus(function () {
		$(this).bind("keydown.keydown00_e1", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd0TagNum1Area.attr("style","");
				_EsdDynamicTransformationScript.esd0TagNum2.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd0TagNum1ContentN.blur(function () {
		$(this).unbind("keydown.keydown00_e1");
	});
	//第二块
	_EsdDynamicTransformationScript.esd0TagNum2.focus(function (e) {
		_EsdDynamicTransformationScript.esd0TagNum2Area.css({"display":"block"});
//		e = $(this).mouseover();
		$(this).bind("keydown.keydown00_2", function (e) {
			if(e.shiftKey&&e.keyCode==9){
//				_EsdDynamicTransformationScript.esd0TagNum1.mouseover();
				_EsdDynamicTransformationScript.esd0TagNum2Area.attr("style","");
				_EsdDynamicTransformationScript.esd0TagNum1Area.css({"display":"block"});
				
				_EsdDynamicTransformationScript.esd0TagNum1ContentN.focus();
				return false;
			}else if (e.keyCode == 9) {
//				_EsdDynamicTransformationScript.esd0TagNum2Content1.focus();
				$("#nav>li:eq(2) .navContent ul a:eq(0)").focus();
				console.log(document.activeElement);
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd0TagNum2.blur(function () {
		$(this).unbind("keydown.keydown00_2");
	});

	_EsdDynamicTransformationScript.esd0TagNum2Content1.focus(function () {
		$(this).bind("keydown.keydown00_s2", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd0TagNum2.focus();
				return false;
			}else if (e.keyCode == 9) {
				
			}
		});
	});

	_EsdDynamicTransformationScript.esd0TagNum2Content1.blur(function () {
		$(this).unbind("keydown.keydown00_s2");
	});

	_EsdDynamicTransformationScript.esd0TagNum2ContentN.focus(function () {
		$(this).bind("keydown.keydown00_e2", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd0TagNum2Area.attr("style","");
				_EsdDynamicTransformationScript.esd0TagNum3.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd0TagNum2ContentN.blur(function () {
		$(this).unbind("keydown.keydown00_e2");
	});
	
	//第三块
	_EsdDynamicTransformationScript.esd0TagNum3.focus(function (e) {
		_EsdDynamicTransformationScript.esd0TagNum3Area.css({"display":"block"});
//		e = $(this).mouseover();
		$(this).bind("keydown.keydown00_3", function (e) {
			if(e.shiftKey&&e.keyCode==9){
//				_EsdDynamicTransformationScript.esd0TagNum2.mouseover();
				_EsdDynamicTransformationScript.esd0TagNum3Area.attr("style","");
				_EsdDynamicTransformationScript.esd0TagNum2Area.css({"display":"block"});
				
				_EsdDynamicTransformationScript.esd0TagNum2ContentN.focus();
				return false;
			}else if (e.keyCode == 9) {
//				_EsdDynamicTransformationScript.esd0TagNum3Content1.focus();
				$("#nav>li:eq(3) .navContent ul a:eq(0)").focus();
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd0TagNum3.blur(function () {
		$(this).unbind("keydown.keydown00_3");
	});

	_EsdDynamicTransformationScript.esd0TagNum3Content1.focus(function () {
		$(this).bind("keydown.keydown00_s3", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd0TagNum3.focus();
				return false;
			}else if (e.keyCode == 9) {
				
			}
		});
	});

	_EsdDynamicTransformationScript.esd0TagNum3Content1.blur(function () {
		$(this).unbind("keydown.keydown00_s3");
	});

	_EsdDynamicTransformationScript.esd0TagNum3ContentN.focus(function () {
		$(this).bind("keydown.keydown00_e3", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd0TagNum3Area.attr("style","");
				_EsdDynamicTransformationScript.esd0TagNum4.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd0TagNum3ContentN.blur(function () {
		$(this).unbind("keydown.keydown00_e3");
	});
	
	//第四块
	_EsdDynamicTransformationScript.esd0TagNum4.focus(function (e) {
		_EsdDynamicTransformationScript.esd0TagNum4Area.css({"display":"block"});
//		e = $(this).mouseover();
		$(this).bind("keydown.keydown00_4", function (e) {
			if(e.shiftKey&&e.keyCode==9){
//				_EsdDynamicTransformationScript.esd0TagNum3.mouseover();
				_EsdDynamicTransformationScript.esd0TagNum4Area.attr("style","");
				_EsdDynamicTransformationScript.esd0TagNum3Area.css({"display":"block"});
				
				_EsdDynamicTransformationScript.esd0TagNum3ContentN.focus();
				return false;
			}else if (e.keyCode == 9) {
//				_EsdDynamicTransformationScript.esd0TagNum4Content1.focus();
				$("#nav>li:eq(4) .navContent ul a:eq(0)").focus();
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd0TagNum4.blur(function () {
		$(this).unbind("keydown.keydown00_4");
	});

	_EsdDynamicTransformationScript.esd0TagNum4Content1.focus(function () {
		$(this).bind("keydown.keydown00_s4", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd0TagNum4.focus();
				return false;
			}else if (e.keyCode == 9) {
				
			}
		});
	});

	_EsdDynamicTransformationScript.esd0TagNum4Content1.blur(function () {
		$(this).unbind("keydown.keydown00_s4");
	});

	_EsdDynamicTransformationScript.esd0TagNum4ContentN.focus(function () {
		$(this).bind("keydown.keydown00_e4", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd0TagNum4Area.attr("style","");
				_EsdDynamicTransformationScript.esd0TagNum5.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd0TagNum4ContentN.blur(function () {
		$(this).unbind("keydown.keydown00_e4");
	});
	
	//第五块
	_EsdDynamicTransformationScript.esd0TagNum5.focus(function (e) {
		_EsdDynamicTransformationScript.esd0TagNum5Area.css({"display":"block"});
//		e = $(this).mouseover();
		$(this).bind("keydown.keydown00_5", function (e) {
			if(e.shiftKey&&e.keyCode==9){
//				_EsdDynamicTransformationScript.esd0TagNum4.mouseover();
				_EsdDynamicTransformationScript.esd0TagNum5Area.attr("style","");
				_EsdDynamicTransformationScript.esd0TagNum4Area.css({"display":"block"});
				
				_EsdDynamicTransformationScript.esd0TagNum4ContentN.focus();
				return false;
			}else if (e.keyCode == 9) {
//				_EsdDynamicTransformationScript.esd0TagNum5Content1.focus();
				//ie测试有问题。用选择器写
				_EsdDynamicTransformationScript.esd0TagNum5Content1.focus();
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd0TagNum5.blur(function () {
		$(this).unbind("keydown.keydown00_5");
	});
	
	_EsdDynamicTransformationScript.esd0TagNum5Content1.focus(function () {
		$(this).bind("keydown.keydown00_e5", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				_EsdDynamicTransformationScript.esd0TagNum5.focus();
				return false;
			}else if (e.keyCode == 9) {
//				$(this).unbind("keydown.keydown00_e5");
				_EsdDynamicTransformationScript.esd0TagNum5Area.attr("style","");
				
				if( $(".page_slide .cyclyImg_pager span:eq(0)").length != 0 ){
					$(".page_slide .cyclyImg_pager span:eq(0)").click();
					$("#Projector .picplay .picbox:eq(0) a:eq(0)").focus();
					return false;
				}
				
				if( $(".breadDiv a:eq(0)").length != 0 ){
					$(".breadDiv a:eq(0)").focus();
					return false;
				}
				
				
			}
		});
	});
	_EsdDynamicTransformationScript.esd0TagNum5Content1.blur(function () {
		$(this).unbind("keydown.keydown00_e5");
	});
	

	



